/**
 * Generate time : 2011-06-27 5:55:00
 * Version : 1.0.1.V20070717
 */
package com.baosight.sczx.zm.cc.domain;

import com.baosight.iplat4j.core.ei.EiColumn;
import com.baosight.iplat4j.ep.DaoEPBase;
import java.util.HashMap;
import java.util.Map;
import com.baosight.iplat4j.util.StringUtils;

/**
 * ZMCC5examineBusinessrate
 * 
 */
public class ZMCC5examineBusinessrate extends DaoEPBase {

	private String fdKeyId = " "; /* 主键 */
	private String fdRateName = " "; /* 业务权重名称 */

	/**
	 * initialize the metadata
	 */
	public void initMetaData() {
		EiColumn eiColumn;

		eiColumn = new EiColumn("fdKeyId");
		eiColumn.setPrimaryKey(true);
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("主键");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdRateName");
		eiColumn.setFieldLength(50);
		eiColumn.setDescName("业务权重名称");
		eiMetadata.addMeta(eiColumn);

	}

	/**
	 * the constructor
	 */
	public ZMCC5examineBusinessrate() {
		initMetaData();
	}

	/**
	 * get the fdKeyId - 主键
	 * 
	 * @return the fdKeyId
	 */
	public String getFdKeyId() {
		return this.fdKeyId;
	}

	/**
	 * set the fdKeyId - 主键
	 */
	public void setFdKeyId(String fdKeyId) {
		this.fdKeyId = fdKeyId;
	}

	/**
	 * get the fdRateName - 业务权重名称
	 * 
	 * @return the fdRateName
	 */
	public String getFdRateName() {
		return this.fdRateName;
	}

	/**
	 * set the fdRateName - 业务权重名称
	 */
	public void setFdRateName(String fdRateName) {
		this.fdRateName = fdRateName;
	}

	/**
	 * get the value from Map
	 */
	@SuppressWarnings("rawtypes")
	public void fromMap(Map map) {

		setFdKeyId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdKeyId")), fdKeyId));
		setFdRateName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdRateName")), fdRateName));
	}

	/**
	 * set the value to Map
	 */
	@SuppressWarnings({ "rawtypes", "unchecked" })
	public Map toMap() {

		Map map = new HashMap();
		map.put("fdKeyId", StringUtils.toString(fdKeyId, eiMetadata.getMeta("fdKeyId")));
		map.put("fdRateName", StringUtils.toString(fdRateName, eiMetadata.getMeta("fdRateName")));

		return map;

	}
}